{extend name="public/base" /}
 {block name="body"}
 <div class="content-tabs">
	<ol class="breadcrumb">
		<li>
			<a href="{:url('index/index')}"><i class="fa fa-home"></i></a>
		</li>
		<li>
			<a href="{:url('index')}">连锁店列表</a>
		</li>
		<li><strong>设置打印机信息</strong></li>
	</ol>
</div>
<div class="row">
	<div class="col-sm-12">
		<div class="ibox float-e-margins">
			<div class="ibox-content">
				<form id="myForm" class="form-horizontal m-t" method="post" action="{:url('prtadd')}">
					<input type="hidden" name="id" value="{$ad.id}" />
					<input type="hidden" name="store_id" value="{$store_id}" />
					<div class="form-group">
						<label class="col-sm-3 control-label">打印机/终端号：</label>
						<div class="input-group col-sm-4">
							<input type="text" id="machine_code" name="machine_code" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label">打印机/密钥：</label>
						<div class="input-group col-sm-4">
							<input type="text" id="msign" name="msign" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label">平台/用户ID：</label>
						<div class="input-group col-sm-4">
							<input type="text" id="partner" name="partner" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label">平台/API密钥：</label>
						<div class="input-group col-sm-4">
							<input type="text" id="apiKey" name="apiKey" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label">平台/用户名：</label>
						<div class="input-group col-sm-4">
							<input type="text" id="ptname" name="ptname" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label">密码：</label>
						<div class="input-group col-sm-4">
							<input type="text" id="password" name="password" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label">打印开关：</label>
						<div class="input-group col-sm-4">
							<label class="checkbox-inline h5">
                                <input type="radio" name="paid" value="0" checked="checked"> 开启
							</label>
							<label class="checkbox-inline h5">
                                <input type="radio" name="paid" value="1" > 关闭
							</label>
						</div>	
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label"></label>
						<div class="input-group col-sm-4">
							<a target="_blank" href="http://yilianyun.10ss.net/user/login">点此前往易联云获取打印机配置</a>
						</div>
					</div>
					<div class="hr-line-dashed"></div>
					<div class="form-group">
						<div class="col-sm-4 col-sm-offset-3">
							<button class="btn btn-primary" type="submit"><i class="fa fa-save"></i> 保存</button>&nbsp;&nbsp;
							<a href="{:url('index')}" class="btn btn-danger"><i class="fa fa-arrow-left"></i> 返回 </a>
						</div>
					</div>
					<div class="form-group">
						<label class="col-sm-3 control-label"></label>
						<div class="input-group col-sm-4">
							1、先按功能键，打开电源</br>
							2、进入WIFI配置方式</br>
							3、选择方式3【浏览器】，连击HOME键3次进入设置</br>
							4、进入方式3，用手机连接WIFI</br>
							5、用手机浏览器输入【192.168.4.1】，输入本地WIFI用户名、密码
						</div>
					</div>
				</form>
			</div>
		</div>
	</div>
</div>
{/block} {block name="script"}
<script src="__JS__/jquery.form.js"></script>
<script src="__LIB__/validate/jquery.validate.min.js"></script>
<script src="__LIB__/validate/messages_zh.min.js"></script>
<script src="__LIB__/validate/add_validate.min.js"></script>
<script src="__LIB__/fileinput/js/fileinput.min.js"></script>
<script src="__LIB__/fileinput/js/locales/zh.js"></script>
<script src="__LIB__/datepicker/WdatePicker.js"></script>
<script>
	$(function() {
		$("#myForm").validate({
			rules: {
				machine_code: "required",
				msign: "required"
			},
			messages: {
				machine_code: ICON.error + "请输入打印机/终端号",
				msign: ICON.error + "请输入打印机/密钥"
			},
			submitHandler: function(form) {
				ajaxForm();
			}
		});
	});
</script>
{/block}